package com.example.lancooznbk.service;

import retrofit2.http.Body;
import retrofit2.http.POST;
import retrofit2.http.Query;
import rx.Observable;
import znbkChangeCollection.ChangeCollectionEntityModel;
import znbkChangeNote.entity.DeleteNoteEntity;
import znbkChangeNote.entity.SaveNoteEntity;
import znbkChangeZsdLearned.entity.ZnbkSaveLearnedZsdEntity;
import znbkTestPaperCtfd.entity.WrongTopicTutoringPaperEntity;
import znbkTestPaperCtfd.entity.WrongTopicTutoringModelEntity;
import znbkTestPaperCtfd.save.SaveWrongTopicTutoringEntity;
import znbkTestPaperRdqh.saveRdqhPaper.SaveWeekAscensionPaperEntity;
import znbkTestPaperRdqh.saveRdqhPaper.SubmitAnswerEntityResultRdqh;
import znbkTestPaperXtfx.saveDiagnosticReportInfo.SaveDiagnosticReportEntity;
import znbkTestPaperXtfx.saveDiagnosticReportInfo.SaveDiagnosticReportResult;
import znbkTestPaperXtfx.saveXtfxPaper.SaveSystemReviewPaperEntity;
import znbkTestPaperXtfx.saveXtfxPaper.SubmitAnswerEntityResultXtfx;

/**
 * Created by Administrator on 2017/8/10/010.
 */

public interface HttpPostServer {

    /*
    *设置试卷模板
    * */
    @POST("api/ZNBK/W_ZNBK_SetPaperTemplet")
    Observable<String> setPaperTemplate(@Query("stuId") String stuId,@Query("stuName") String stuName,@Query("subjectId") String subjectId,
                                                         @Query("stageNo") String stageNo,@Query("templetId") String templetId,
                                                         @Query("templetName") String templetName,@Query("lastTempletId") String lastTempletId,
                                                         @Query("lastTempletName") String lastTempletName,@Query("zsdDomain") String zsdDomain);

/******************************************************************************************************************
 * *************************************************分界线 hyznbk************************************************************************
 * ****************************************************************************************************************/

     /*
    * znbk更改试题的收藏信息（收藏/取消收藏试题）
    * http://172.16.41.235:2018/api/ZNBK/W_ZNBK_ChangePersonalFavourite?StuID=zxstu8&SubjectID=C&StageNo=C&QuesId= CCAE07073ABA100001z&Theme= Unit1.1&ResType=1&Flag=1
    * */
    @POST("api/ZNBK/W_ZNBK_ChangePersonalFavourite")
    Observable<String> changeCollection(@Body ChangeCollectionEntityModel changeCollectionEntityModel);

    /*
    * 提交难点训练作答信息
    * http://172.16.41.235:2018/api/ZNBK/W_ZNBK_SaveHardQues
    * {"QuesID":"CCAD05040DHA106007K","StuID":"LgStudent","StuName":"张三","SubjectID":"C","StageNo":"C","ItemFrom" :4,"TypeID":"N","TypeName":"词汇填空",
        "QuesBrief":"我是一个粉刷匠","StuAnswer":"哈哈哈","CorrectRate":0.7,"TotalItemCount":10,"AnswerItemCount":8,"Duration":100,"AnswerState":1
    }
    * */
//    @POST("api/ZNBK/W_ZNBK_SaveHardQues")
//    Observable<String> saveTrainingDifficultProblemsJson(@Body SaveTrainingDifficultProblemsEntity saveTrainingDifficultProblemsEntity);


    /*
    * 获取错题辅导试题详情
    * http://172.16.41.235:2018/api/ZNBK/W_ZNBK_WrongQuesTutor
    *
    * {
  "QuesID" : "CCAE08070DHE10V00Y2",
  "SubjectID" : "C",
  "StuAnswer" : [
    {
      "ChildIndex" : 1,
      "SubChildList" : [
        {
          "StuAssess" : "",
          "SubChildIndex" : 1,
          "StuAnswer" : "A",
          "UploadPath" : ""
        }
      ]
    },
    {
      "ChildIndex" : 2,
      "SubChildList" : [
        {
          "StuAssess" : "",
          "SubChildIndex" : 1,
          "StuAnswer" : "B",
          "UploadPath" : ""
        }
      ]
    },
    {
      "ChildIndex" : 3,
      "SubChildList" : [
        {
          "StuAssess" : "",
          "SubChildIndex" : 1,
          "StuAnswer" : "C",
          "UploadPath" : ""
        }
      ]
    }
  ],
  "ItemFrom" : 0,
  "CreateTime" : "2018-3-2 14:06:20",
  "StuID" : "zxstu8",
  "StageNo" : "C",
  "StuName" : "朱小玲"
}
    * */

    @POST("api/ZNBK/W_ZNBK_WrongQuesTutor")
    Observable<WrongTopicTutoringPaperEntity> postWrongTopicTutoringJson(@Body WrongTopicTutoringModelEntity wrongTopicTutoringModelEntity);


    /*
    * 提交错题辅导作答信息
    * http://172.16.41.245:2015/api/ZNBK/W_ZNBK_SaveRecQues
    *[{
        "QuesID":"CCAD05040DHN103006L",
        "StuID":"LgStudent",
        "StuName":"张三",
        "SubjectID":"C",
        "StageNo":"C",
        "CorrectRate":0.1,
        "TotalItemCount":1,
        "AnswerItemCount":1,
        "Duration":100,
        "AnswerState":1,
        "StuAnswer":"A",
        "PimitiveQuesID":"CCAD05040DHA106007K",
        "StepFlag":2,
        "AllQuesTotalCount":1
        }]
    * */
    @POST("api/ZNBK/W_ZNBK_SaveRecQues")
    Observable<String> saveWrongTopicTutoringPaperEntity(@Body SaveWrongTopicTutoringEntity saveWrongTopicTutoringEntity);


    /*
    * 保存笔记更改信息
    * http://172.16.41.235:2018/api/ZNBK/W_ZNBK_SavePersonalNote
    * { "Note" : { "StuID" : "zxstu8", "ResType" : "Q", "SubjectID" : "C", "NoteID" : "", "StageNo" : "C",
    * "QuesID" : "CCAC04012DHA108007W" }, "Title" : " ", "Content" : "Thur day go 1wwww11" }
    * */
    @POST("api/ZNBK/W_ZNBK_SavePersonalNote")
    Observable<String> savePersonalNote(@Body SaveNoteEntity saveNoteEntity);

    /*
    * 删除笔记信息
    * http://172.16.41.235:2018/api/ZNBK/W_ZNBK_DeletePersonalNote
    * { "StuID" : "zxstu28", "ResType" : "A", "SubjectID" : "C", "NoteID" : "6b730608-4ff2-4765-b886-de4a4351203c",
    * "StageNo" : "C", "QuesID" : "CCAC04012DHA108009r" }
    * */
    @POST("api/ZNBK/W_ZNBK_DeletePersonalNote")
    Observable<String> deletePersonalNote(@Body DeleteNoteEntity deleteNoteEntity);


    /*
    * 保存知识点
    * http://172.16.41.235:2018/api/ZNBK/W_ZNBK_SaveLearnedZSD
    * {"ZSD":{"ZSDCode":"CC04117D5AaC3CAAF","ZSDName":"information"},"SubjectID":"C","StageNo":"C","StuID":"basestu20","From":0}
    * */
    @POST("api/ZNBK/W_ZNBK_SaveLearnedZSD")
    Observable<String> saveLearnedZSD(@Body ZnbkSaveLearnedZsdEntity znbkSaveLearnedZsdEntity);

    /*
    * 保存复习诊断报告
    * http://172.16.41.235:2018/api/ZNBK/W_ZNBK_SaveDiagnosticReportInfo?
    * */
    @POST("api/ZNBK/W_ZNBK_SaveDiagnosticReportInfo")
    Observable<SaveDiagnosticReportResult> saveDiagnosticReportInfo(@Body SaveDiagnosticReportEntity saveDiagnosticReportEntity);

    /*
    * 保存试卷及试卷试题的作答信息：系统复习
    * http://172.16.41.235:2018/api/ZNBK/W_ZNBK_SavePaperItemAnswerDetail
    * */
    @POST("api/ZNBK/W_ZNBK_SavePaperItemAnswerDetail")
    Observable<SubmitAnswerEntityResultXtfx> saveXtfxPaperItemAnswerDetail(@Body SaveSystemReviewPaperEntity saveSystemReviewPaperEntity);

    /* 保存试卷及试卷试题的作答信息：弱点强化
    * http://172.16.41.235:2018/api/ZNBK/W_ZNBK_SavePaperItemAnswerDetail
    * */
    @POST("api/ZNBK/W_ZNBK_SavePaperItemAnswerDetail")
    Observable<SubmitAnswerEntityResultRdqh> saveRdqhPaperItemAnswerDetail(@Body SaveWeekAscensionPaperEntity saveWeekAscensionPaperEntity);

}
